/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package GUI;

import java.awt.Color;
import java.awt.Graphics;
import javax.swing.JComponent;

/**
 *
 * @author David
 */
public class Planeta extends JComponent{
    
    private int x;
    private int y;
    private int numPlaneta;
    private Graphics g;
    
    Planeta(int x,int y,int nP)
    {
        this.x=x;
        this.y=y;
        this.numPlaneta=nP;
               
    }
    
    public void paintComponent(Graphics g)
    {
        super.paintComponent(g);
        
        g.setColor(Color.RED);
        g.fillOval(x, y,50, 50);
        
    }
    
    public void setColorPlaneta(Color c)
    {
        g.setColor(c);
        g.fillOval(x, y,50, 50);
    }        

}
